/*
 * CrystalAnalysisWorker.h
 *
 *  Created on: Aug 10, 2012
 *      Author: koschke
 */

#ifndef CRYSTALANALYSISWORKER_H_
#define CRYSTALANALYSISWORKER_H_

#include <votca/csg/csgapplication.h>
#include <votca/csg/beadlist.h>
#include "OrderParameter.h"


#include "TypesAndTools.h"

using namespace votca::csg;
using namespace votca::tools;

class CrystalAnalysisWorker: public CsgApplication::Worker {
public:
	CrystalAnalysisWorker(double _cutOff, double _threshold);
	virtual ~CrystalAnalysisWorker();
	void EvalConfiguration(Topology *top, Topology *top_ref);
	template<class OP> void initOrderParameter(Topology *_top) {
		orderParameter = new OP(_top, &beadList);
	}
	;
	OrderParameter * orderParameter;

private:
	BeadList beadList;
//double time;
	//Todo the next two parameters should not be here!
	double cutOff;
	double threshold;
//string _beadcrit;
//NBListGrid * nbListGrid;
};

#endif /* CRYSTALANALYSISWORKER_H_ */
